package top.zxybird.common.model;

import top.zxybird.common.constants.ClientType;
import top.zxybird.common.constants.DeviceType;

import java.io.Serializable;

/**
 * 客户端信息
 * 
 * @author Rick
 *
 *         2014年9月11日 下午4:18:52
 */
public class ClientInfo implements Serializable {

  /**
   *
   */
  private static final long serialVersionUID = 1324426768544734070L;

  /**
   * 客户端类型
   */
  private ClientType clientType;

  private DeviceType device;

  /**
   * 版本号
   */
  private String version;

  /**
   * HTTP header user-agent
   */
  private String userAgent;

  /**
   * 市场渠道号
   */
  private String channel;

  /**
   * 设备号，客户端设备的唯一标识。
   */
  private String deviceId;

  /**
   * 设备 mac
   */
  private String mac;

  private String ip;

  private String longitude;

  private String latitude;

  private String bundleId;

  public String getIp() {
    return ip;
  }

  public void setIp(String ip) {
    this.ip = ip;
  }

  public ClientType getClientType() {
    return clientType;
  }

  public void setClientType(ClientType clientType) {
    this.clientType = clientType;
  }

  public String getChannel() {
    return channel;
  }

  public void setChannel(String channel) {
    this.channel = channel;
  }

  public String getLongitude() {
    return longitude;
  }

  public void setLongitude(String longitude) {
    this.longitude = longitude;
  }

  public String getLatitude() {
    return latitude;
  }

  public void setLatitude(String latitude) {
    this.latitude = latitude;
  }

  public String getDeviceId() {
    return deviceId;
  }

  public void setDeviceId(String deviceId) {
    this.deviceId = deviceId;
  }

  public String getMac() {
    return mac;
  }

  public void setMac(String mac) {
    this.mac = mac;
  }

  public String getUserAgent() {
    return userAgent;
  }

  public void setUserAgent(String userAgent) {
    this.userAgent = userAgent;
  }

  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("ClientInfo:[").append("clientType=").append(clientType).append(",userAgent=").append(userAgent)
        .append(",ip=").append(ip).append(",deviceId=").append(deviceId).append(",channel=").append(channel)
        .append(",mac=").append(mac).append(",latitude=").append(latitude).append(",longitude=").append(longitude)
        .append("].");
    return sb.toString();
  }

  public String getVersion() {
    return version;
  }

  public void setVersion(String version) {
    this.version = version;
  }

  public DeviceType getDevice() {
    return device;
  }

  public void setDevice(DeviceType device) {
    this.device = device;
  }

  public String getBundleId() {
    return bundleId;
  }

  public void setBundleId(String bundleId) {
    this.bundleId = bundleId;
  }

}
